# Copyright (C) Kumo inc. and its affiliates.
# Author: Jeff.li lijippy@163.com
# All rights reserved.
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published
# by the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with this program.  If not, see <https:#www.gnu.org/licenses/>.
#
#[[
add_executable(
  pollux_dwio_arrow_parquet_writer_test
  BloomFilterTest.cpp
  ColumnReaderTest.cpp
  ColumnWriterTest.cpp
  EncodingTest.cpp
  FileDeserializeTest.cpp
  FileSerializeTest.cpp
  MetadataTest.cpp
  PageIndexTest.cpp
  PropertiesTest.cpp
  SchemaTest.cpp
  StatisticsTest.cpp
  TypesTest.cpp)

add_test(pollux_dwio_arrow_parquet_writer_test
         pollux_dwio_arrow_parquet_writer_test)

target_link_libraries(
  pollux_dwio_arrow_parquet_writer_test
  pollux_dwio_arrow_parquet_writer_test_lib
  GTest::gmock
  GTest::gtest
  GTest::gtest_main
        Arrow::arrow_static
        Arrow::arrow_testing
  pollux_dwio_native_parquet_reader
  pollux_temp_path)

add_library(
  pollux_dwio_arrow_parquet_writer_test_lib
  BloomFilter.cpp
  BloomFilterReader.cpp
  ColumnReader.cpp
  ColumnScanner.cpp
  FileReader.cpp
  TestUtil.cpp
  XxHasher.cpp)

target_link_libraries(
  pollux_dwio_arrow_parquet_writer_test_lib Arrow::arrow_static
  pollux_dwio_arrow_parquet_writer_lib GTest::gtest)
]]